/**
 * losenote.com Inc.
 * Copyright (c) 2013-2013 All Rights Reserved.
 */
package com.losenote.core.impl;

import org.springframework.beans.factory.annotation.Autowired;

import com.losenote.core.UserComponent;
import com.losenote.model.UserInfo;
import com.losenote.model.ct.UserInfoConvertor;
import com.losenote.orm.UserInfoDO;
import com.losenote.orm.UserInfoDODAO;

/**
 * 用户操作信息
 * 
 * @author danjingyu
 * @version $Id: UserComponentImpl.java, v 0.1 2013-10-30 下午11:23:19 danjingyu Exp $
 */
public class UserComponentImpl implements UserComponent {

    /**用户操作信息*/
    @Autowired
    private UserInfoDODAO userInfoDODAO;

    /** 
     * @see com.losenote.core.UserComponent#queryById(int)
     */
    @Override
    public UserInfo queryById(int id) {
        UserInfoDO userInfoDO = userInfoDODAO.selectByPrimaryKey(id);
        return UserInfoConvertor.fromDO(userInfoDO);
    }

    public void setUserInfoDODAO(UserInfoDODAO userInfoDODAO) {
        this.userInfoDODAO = userInfoDODAO;
    }

}
